package com.google.code.jbauble.dao;

import java.sql.Connection;
import java.sql.SQLException;
import java.util.List;

import org.apache.commons.dbutils.DbUtils;
import org.apache.commons.dbutils.QueryRunner;
import org.apache.commons.dbutils.ResultSetHandler;
import org.apache.commons.dbutils.handlers.BeanHandler;
import org.apache.commons.dbutils.handlers.BeanListHandler;
import org.apache.commons.dbutils.handlers.ScalarHandler;

import com.google.code.jbauble.exception.DataAccessException;

public interface SqlNative {
	public Connection getConnection(int type) throws SQLException;
	
	public List queryForList(String sql, Object[] objs, final Class type);

	public Object queryForObject(String sql, Object[] objs, final Class type);
	
	public Long queryForLong(String sql, Object[] objs);
	
	public int execute(String sql, Object[] objs) throws DataAccessException;
	
	public long executeInsert(final String sql, final Object[] objs) throws DataAccessException;
}
